Add grant table support to block tap.
authorakw27@arcadians.cl.cam.ac.uk <akw27@arcadians.cl.cam.ac.uk>
Tue, 16 Aug 2005 10:12:18 +0000 (10:12 +0000)
committerakw27@arcadians.cl.cam.ac.uk <akw27@arcadians.cl.cam.ac.uk>
Tue, 16 Aug 2005 10:12:18 +0000 (10:12 +0000)
commitc631e99bf4e18f33efa9f7a472215131436f58a8
treedc3ac080a9e82d81b8261417583c08add03a99ae
parent3eeeaba7c99cc12633fc44bef2b26fa1f438e3ba
Add grant table support to block tap.

This patch adds grant table support to the block tap.  The AIO support
introduced in patch 9f0eff879d8913a824280cf67658a530c80e8424 still
works -- The tap code maps a granted page twice, once in kernel and
once in user.  The kernel page is patched into the p2m table and pages
added to the user vm_area are mapped to the appropriate underlying
struct pages using the VM_FOREIGN hooks in get_user_pages().

Comparing block IO from dom0 to the existing block backend, and to the
tap managing the same partition as the BE from user space with AIO, I
get the following performance:

Version  1.03       ------Sequential Output------ --Sequential Input- --Random-
                    -Per Chr- --Block-- -Rewrite- -Per Chr- --Block-- --Seeks--
Machine        Size K/sec %CP K/sec %CP K/sec %CP K/sec %CP K/sec %CP  /sec %CP
xen0             2G 31198  95 56818   8 20967   2 28415  77 59595   4 264.9   0
xenU-blkbe2cpuGT 2G 31157  96 54026  10 25585   4 30664  90 64919   7 292.7   0
xenU-blktp2cpuGT 2G 32313  97 54217   8 20950   3 28117  87 65924   4 191.8   0

Signed-off-by: andrew.warfield@cl.cam.ac.uk
linux-2.6-xen-sparse/drivers/xen/blktap/blktap.c
linux-2.6-xen-sparse/drivers/xen/blktap/blktap.h
linux-2.6-xen-sparse/drivers/xen/blktap/blktap_controlmsg.c
linux-2.6-xen-sparse/drivers/xen/blktap/blktap_userdev.c